//
//      (c) 2008 mocom software GmbH & Co KG 
//		for European Microsoft Innovation Center
//
//      $Author: volker $
//      $Date: 2009-02-26 16:55:56 +0100 (Do, 26 Feb 2009) $
//      $Revision: 276 $

#ifndef _HAG_USART_OPTIONS
#define _HAG_USART_OPTIONS 1

enum {
	USART_OPT_NOP=0,
	//--//
	USART_OPT_SET_RX_CALLBACK,
	USART_OPT_SET_RX_CALLBACK_ARGUMENT,
	USART_OPT_SET_TX_CALLBACK,
	USART_OPT_SET_TX_CALLBACK_ARGUMENT,
	USART_OPT_SET_MODEM_CALLBACK,
	USART_OPT_SET_MODEM_CALLBACK_ARGUMENT,
	USART_OPT_SET_LINE_CALLBACK,
	USART_OPT_SET_LINE_CALLBACK_ARGUMENT,
	//--//
	USART_OPT_ADD_TO_RQMASK,
	USART_OPT_DEL_FROM_RQMASK,
	//--//
	USART_OPT_RTS,
	USART_OPT_DTR,
	USART_OPT_CTS,
	USART_OPT_DSR,
	USART_OPT_DCD,
	USART_OPT_RI,
	//--//
	USART_OPT_DUPLEX,
};	

enum {
	USART_OPT_HALFDUPLEX=0,
	USART_OPT_FULLDUPLEX=1
};

enum {
	USART_ARG_NOP=0x00,
	USART_ARG_RISE=0x1,
	USART_ARG_FALL=0x2,
};


BOOL CPU_USART_SetOption(int ComPortNum, int Feature, UINT32 value);
BOOL CPU_USART_GetOption(int ComPortNum, int Feature, UINT32 *Value);
unsigned CPU_USART_WriteBurstToTxBuffer( int comPort,  UINT8 *data, unsigned len );

#endif // _HAG_AT91_SAM9261_H_1
